                        <a name="comments"></a>
                        <{if $smarty.const.YKPL eq 1 or $smarty.session.customersinfo.customers_id}>
                            <script type="text/javascript">
                            $(document).ready(function(){ // 当页面加载完毕的时候
                            			$('#newcomment').click(function(){ // “提交”的按钮被点击
                                        var review_text = $('#review_text').val();
                                        $('#result').css('display','block');
                                        if(review_text!=''){
                                			var formdata = {
                                			'commentnews_id' : $('#commentnews_id').val(),
                                			'rating' : $("input[name='rating']:checked").val(),
                                			'review_text': review_text,
                                		      };
                                			$("#result").ajaxSend(function(e,xhr,opt){
                                			     $(this).html("Loading.....");
                           			          });
                                			$.getJSON('<{spUrl c=news a=savecomment action=process}>', formdata, function(json){
                                			     if(json.status=='y'){
                                                    $('.FCOMENT').css('display','none');
                                                 };
                                                 $('#result').html(json.info);
                                                });
                                        }else{
                                            $('#result').html('Error comment failed!');
                                        };
                            		});
                            });
                            </script>                       
                        <{/if}>
                        <div id="comment">
                            <h2><{GetCommentNewsCount newsid=$news.news_id}> Comments</h2>
                               <ul class="commentlist">
                                <{foreach item=item key=key from=$Commentlist}>
                                 <li>
                			       <div class="nameatime"><a href="<{spUrl c=news a=view alias=$news.alias}>" name="comments<{$item.news_comments_id}>"><{if $item.name neq ''}><{$item.name}><{else}><{T w='Guest'}><{/if}></a> <br /><{FormatDateAgo date=$item.date_add}></div>
                			       <div class="comment_con"><{$item.review_text|escape: 'htmlall'}></div>
                                 </li>
                                <{/foreach}>
                              </ul>
                            <div class="leave_comment">  
                             <h3>leave a reply</h3>
                             <div id="result"></div>
                	         <div class="fieldblock FCOMENT">
                             <br />
                		       <label for="comment" class="graylabel">Comment:</label>
                		       <div class="input hover">
                               <input type="hidden" value="<{$news.news_id}>" name="commentnews_id" id="commentnews_id"/>
                               <textarea tabindex="4" rows="" cols="" id="review_text" name="review_text" class="short"></textarea>
                               
                               </div>
                	         </div>
                	         <div class="clear"></div>
                	         <input class="news_submit news_search_btn FCOMENT" type="submit" value="Submit" name="newcomment" id="newcomment" <{if $smarty.const.YKPL eq 0 && $smarty.session.customersinfo.customers_id eq ''}>disabled="disabled"<{/if}>/>

                            </div>
                         </div>